package com.caisejingyu.whales.home.devices.printer;

import android.os.Build;

/**
 * Created by guazi on 16-10-22.
 */

public class CpuId {
    static public String getCpuId() {
//        if (true) {
//            return "Taoisym";
//        }
        try {
            String line = Shell.exec("cat /proc/cpuinfo | grep 'Serial'");
            String cpuid = line.substring(line.length() - "bd71906049c3ca9e".length() - 1).trim();
            return cpuid;
        } catch (Exception e) {
            return "";
        }
    }

    public static String getCpu() {
        return android.os.Build.CPU_ABI2;
        //String line = new Shell().exec("cat /proc/cpuinfo | grep 'model name'");
        //return line.trim();

    }

    public static String getVersion() {
        return Build.VERSION.RELEASE;
    }
}
